Component({
  data: {
    show: false,
    selected: null,
    color: "#fff",
    selectedColor: "#4050B5",
    list: [{
        pagePath: "/pages/home/home",
        iconPath: "/image/homefill.png",
        selectedIconPath: "/image/2homefill.png",
        text: "首页"
      }, {
        pagePath: "/pages/shop/shop",
        iconPath: "/image/shopfill.png",
        selectedIconPath: "/image/4shopfill.png",
        text: "店铺"
      },
      {
        pagePath: "/pages/addArticle/addArticle",
        iconPath: "/image/add.png",
        selectedIconPath: "/image/1add.png",
      },
      {
        pagePath: "/pages/order/order",
        iconPath: "/image/order_fill.png",
        selectedIconPath: "/image/3order_fill.png",
        text: "订单"
      }, {
        pagePath: "/pages/about/about",
        iconPath: "/image/user.png",
        selectedIconPath: "/image/5user.png",
        text: "关于"
      }
    ]
  },
  attached() {},
  methods: {
    switchTab(e) {
      const data = e.currentTarget.dataset
      const url = data.path
      wx.switchTab({
        url
      })
    }
  }
})